package lab2;

public class TensorflowFactory extends AbstractFactory{
    private static TensorflowFactory instance;
    private TensorflowFactory(){}

    public static TensorflowFactory getInstance(){
        if (instance == null){
            instance = new TensorflowFactory();
        }
        return instance;
    }

    @Override
    Dataset createDataset() {
        return new TensorflowDataset();
    }

    @Override
    Layer createLayer() {
        return new TensorflowLayer();
    }

    @Override
    LossFunction createLossFunction() {
        return new TensorflowLossFunction();
    }

    @Override
    Optimizer createOptimizer() {
        return new TensorflowOptimizer();
    }

    @Override
    Model createModel() {
        return new TensorflowModel();
    }
}
